Skip to content

Instantly share code, notes, and snippets.

@maxrodrigo
maxrodrigo / git-split-and-push.sh
Last active June 1, 2024 09:21
Split a repository into batches to avoid `pack exceeds maximum allowed size` on push
# Split a repository into batches to avoid `pack exceeds maximum allowed size` on git push
REMOTE=origin
BRANCH=$(git rev-parse --abbrev-ref HEAD)
BATCH_SIZE=500
# check if the branch exists on the remote
if git show-ref --quiet --verify refs/remotes/$REMOTE/$BRANCH; then
# if so, only push the commits that are not on the remote already
range=$REMOTE/$BRANCH..HEAD
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active June 1, 2024 09:18
国内的 Docker Hub 镜像加速器,由国内教育机构与各大云服务商提供的镜像加速服务 | Dockerized 实践 https://github.com/y0ngb1n/dockerized

Docker Hub 镜像加速器

国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。Docker 官方和国内很多云服务商都提供了国内加速器服务。

Dockerized 实践 https://github.com/y0ngb1n/dockerized

配置加速地址

Ubuntu 16.04+、Debian 8+、CentOS 7+

@yookoala
yookoala / 90-mac-superdrive.rules
Last active June 1, 2024 09:16
udev rules to use Apple SuperDrive on Linux
#
# Apple SuperDrive initialization rule
#
# See: https://gist.github.com/yookoala/818c1ff057e3d965980b7fd3bf8f77a6
ACTION=="add", ATTRS{idProduct}=="1500", ATTRS{idVendor}=="05ac", DRIVERS=="usb", RUN+="/usr/bin/sg_raw %r/sr%n EA 00 00 00 00 00 01"
@adrianhajdin
adrianhajdin / App.css
Last active June 1, 2024 09:14
Build and Deploy a Full Stack Realtime Chat Messaging App with Authentication & SMS Notifications
:root {
--primary-color: #005fff;
--primary-color-alpha: #005fff1a;
}
html,
body {
margin: 0;
padding: 0;
height: 100%;
@BillRaymond
BillRaymond / GitHub Pages Jekyll Dockerfile
Last active June 1, 2024 09:13
GitHub Pages and Jekyll Dockerfile
# "#################################################"
# Dockerfile to build a GitHub Pages Jekyll site
# - Ubuntu 22.04
# - Ruby 3.1.2
# - Jekyll 3.9.3
# - GitHub Pages 288
#
# This code is from the following Gist:
# https://gist.github.com/BillRaymond/db761d6b53dc4a237b095819d33c7332#file-post-run-txt
#
@morrolinux
morrolinux / instructions.md
Last active June 1, 2024 09:11
FIrefox - Vertical tab bar with auto hide

What to expect

Graphical aspect may vary depending on your choices in following the instructions below, but the end result should look something like this:

immagine

Enable Firefox features

@MichelleLindseyV
MichelleLindseyV / school-catalogue.js
Created January 9, 2022 19:36
School catalogue project from Codecademy: classes and class inheritance
class School {
constructor(name, level, numberOfStudents) {
this._name = name;
this._level = level;
this._numberOfStudents = numberOfStudents;
}
get name() {
return this._name;
}
get level() {
@mjkstra
mjkstra / arch_linux_installation_guide.md
Last active June 1, 2024 09:10
A modern, updated installation guide for Arch Linux with BTRFS on an UEFI system
@Faraz-mobin17
Faraz-mobin17 / settings.json
Created June 1, 2024 09:07
create your vscode minimalist and beautiful with this settings file
{
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"workbench.iconTheme": "symbols",
"php.validate.executablePath": "E:\\xampp\\php\\php.exe",
"editor.formatOnSave": true,
"editor.smoothScrolling": true,
"editor.fontWeight": "450",
"editor.cursorStyle": "block",
"editor.cursorBlinking": "phase",